package com.ta.gulimall.common.utils;

import java.util.Random;

public class RandomUtils {

    /**
     * 生成四位随机数
     * @return
     */
    public static String GenerateAuthCode(){
        String code = "";
        for (int i = 0; i < 4; i++) {
            int math = new Random().nextInt(9);
            code += String.valueOf(math);
        }
        return code;
    }
}
